package cn.edu.java.internet;

import java.io.IOException;
import java.net.*;

public class DatagramSocketServer {
    public static void main(String[] args) throws IOException {
        DatagramSocket datagramSocket = new DatagramSocket();

        String s = "hello,i am wang kang.";
        datagramSocket.send(new DatagramPacket(s.getBytes(), 0, s.length(), InetAddress.getByName("localhost"), 88));

        datagramSocket.close();
    }
}
